<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="UTF-8">
    <title>Thymeleaf3 + Servlet3 示例</title>
</head>
<body>
    <table border="1">
        <thead>

        <tr>
            <td>id</td>
            <td>员工名</td>
            <td>登录名</td>
            <td>phone</td>
            <td>email</td>
            <td>status</td>
            <td>departmentid</td>
            <td>role</td>
            <td>password</td>
            <td>操作</td>
        </tr>
        </thead>
        <tbody>
<!--        EL-&#45;&#45;expression language  表达式语言，简化-->
<!--自定义变量名称，相当于for循环指针变量，对象.属性 （树状写法）-->
        <tr th:each="employee:${employeeList}">
            <td th:text="${employee.employeeId}" />
            <td th:text="${employee.employeeName}"></td>
            <td th:text="${employee.username}"></td>
            <td th:text="${employee.phone}"></td>
            <td th:text="${employee.email}"></td>
            <td th:text="${employee.status}"></td>
            <td th:text="${employee.departmentId}"></td>
            <td th:text="${employee.role}"></td>
            <td th:text="${employee.password}"></td>
            <td ><a th:href="@{DeleteEmployeeServlet(employeeId=${employee.employeeId})}">删除</a>
                <a th:href="@{ToUpdateEmployeeServlet(employeeId=${employee.employeeId})}">修改</a></td>
        </tr>
        </tbody>
    </table>
</body>
</html>
